<h1>
<?
if($mode=='add')	echo 'Thêm mới quảng cáo';
if($mode=='edit')	echo 'Sửa quảng cáo';
?>
</h1>
	<div class="content_block">
		<div class="form_tbl" id="slides">
			
		
				<span class="border_d clearfix">
					<a name="form"></a>
					<form name="themeform" enctype="multipart/form-data" method="post">
						<div class="form_item">
							<label><span class="required_marker">*</span> Status:</label>
							<?=ipos_status('adv_status',$adv_status);?>
						</div>
						<div class="form_item">
							<label><span class="required_marker">*</span> Phân loại:</label>
							<?=ipos_advphanloai($adv_phanloai);?>
						</div>
						<div class="form_item">
							<label><span class="required_marker">*</span> Vị trí hiện thị:</label>
							<?=ipos_adv_list($adv_vitri);?>
						</div>
						<div class="form_item">
							<label><span class="required_marker">*</span> Số thứ tự:</label>
							<input class="flat" size="30" name="adv_stt" value="<?=$adv_stt;?>"  maxlength="250">
						</div>

						<div class="form_item">
							<label><span class="required_marker">*</span> Tên quảng cáo:</label>
							<input class="flat" size="30" name="adv_name" value="<?=$adv_name;?>" maxlength="250">
						</div>
						<div class="form_item">
							<label><span class="required_marker">*</span> Link quảng cáo:</label>
							<input class="flat" size="30" name="adv_url" value="<?=$adv_url;?>" maxlength="250">
						</div>
						<div class="form_item">
							<label><span class="required_marker">*</span> Chọn file upload:</label>
                            <div style="float:left;"><input style="height:18px; width: 320px;" value="<?=$adv_img;?>" name="adv_img_name" id="adv_img_name" type="text" readonly="readonly" /></div>
							<div style="float:left;" class="browse"><input name="adv_img" id="adv_img" type="file"></div>
                            <div style="clear:both;"></div>
						</div>
						<script>
                        $('#adv_img').change(function(){
                            $('#adv_img_name').val($(this).val());
                        });
                        </script>
						<div class="form_item">
							<label style="color:#777;padding-top:10px;"><span class="required_marker">*</span> Phần bắt buộc phải điền</label>
							<span onmouseout="this.className='mb_btn1'" onmouseover="this.className='mb_btn1_hover'" class="mb_btn1">
								<button value="Submit" name="submit" type="submit">Gửi đi</button>
							</span>
						</div>
					</form>
					
				</span>

			</div>
		</div>
<script language="JavaScript" type="text/javascript">
  var frmvalidator  = new Validator("themeform");
  frmvalidator.addValidation("cat_name","req","Vui lòng nhập tên danh mục");  
  frmvalidator.addValidation("cat_stt","req","Vui lòng nhập số thứ tự danh mục");
</script>